<?php

use think\migration\Migrator;
use think\migration\db\Column;

class CreateJpushTask extends Migrator
{
    public function up(){
        $table = $this->table('jpush_task');
//        $table->addColumn('task_type','string',['limit'=>255,'comment'=>'任务类型'])
//            ->addColumn('content','text',['comment'=>'推送内容'])
//            ->addColumn('user_id','integer',['limit'=>10,'comment'=>'用户id'])
//            ->addForeignKey('user_id', 'user', 'id', ['delete'=> 'CASCADE'])
//            ->addColumn('execute_time','integer',['default'=>0,'comment'=>'执行时间'])
//            ->create();
    }
    public function down(){
        $this->dropTable('jpush_task');
    }
}
